import {defineStore} from "pinia";

export const userAuthStore = defineStore("userAuthStore", {
    state: () => ({
        id: "",
        name: "",
        permissions:[]
    }),
    actions: {
       initAuth(){
           this.$state = JSON.parse(localStorage.getItem("web-auth-plat")) || {id: "", name: "", permissions:[]}
       },
    }
})